agents
Class SimpleANAC2013Agent
java.lang.Object
negotiator.Agent
agents.SimpleANAC2013Agent
public class SimpleANAC2013Agent
- extends Agent
This agent is an example of how to create an ANAC2013 agent which learns
during the tournament. This agent is a variant of the random agent.
- Author:
- M. Hendrikx
|
Method Summary |
Action |
chooseAction()
Accept if the utility of the opponent's is higher than the target utility;
else return a random bid with a utility at least equal to the target utility. |
void |
endSession(NegotiationResult result)
Set the target utility for the next match on the same preference profile. |
java.lang.String |
getName()
|
static java.lang.String |
getVersion()
|
void |
init()
Initialize the target utility to MAX(rv, max). |
void |
ReceiveMessage(Action opponentAction)
Retrieve the bid from the opponent's last action. |
| Methods inherited from class negotiator.Agent |
getAgentID, getParameterValues, getSessionNumber, getSessionsTotal, getStrategyParameters, getUniqueIdentifier, getUtility, internalInit, isUIAgent, loadSessionData, parseStrategyParameters, restartDataObjectsFolder, saveSessionData, setAgentID, setName, sleep |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SimpleANAC2013Agent
public SimpleANAC2013Agent()
init
public void init()
- Initialize the target utility to MAX(rv, max). Where rv is the reservation value
of the preference profile and max is the highest utility received on the current
preference profile.
- Overrides:
init in class Agent
getVersion
public static java.lang.String getVersion()
getName
public java.lang.String getName()
- Overrides:
getName in class Agent
- Returns:
- name of the agent.
endSession
public void endSession(NegotiationResult result)
- Set the target utility for the next match on the same preference profile.
If the received utility is higher than the current target, save the
received utility as the new target utility.
- Overrides:
endSession in class Agent
- Parameters:
result - discounted utility of previous session round.
ReceiveMessage
public void ReceiveMessage(Action opponentAction)
- Retrieve the bid from the opponent's last action.
- Overrides:
ReceiveMessage in class Agent
chooseAction
public Action chooseAction()
- Accept if the utility of the opponent's is higher than the target utility;
else return a random bid with a utility at least equal to the target utility.
- Specified by:
chooseAction in class Agent
- Returns:
- (should return) the bid-action the agent wants to make.